document.write("<div class=\"modal fade\" id=\"dlg_comfrim\" tabindex=\"-1\" role=\"dialog\" aria-hidden=\"true\">");
document.write("<div class=\"modal-dialog modal_delete\"> ");
document.write("<div class=\"modal-content\">");
document.write("<div class=\"modal-header\">");
document.write("<button type=\"button\" class=\"close\" data-dismiss=\"modal\" onclick=\"_closeDlg();\" aria-label=\"Close\">");
document.write("<span aria-hidden=\"true\">&times;</span>");
document.write("</button>");
document.write("<h4 class=\"modal-title\"><span id=\"comfrim_title\" ></span></h4>");
document.write("</div>");
document.write("<div class=\"modal-body\">");
document.write("<div class=\"dot_cont\">");
document.write("<h4><span id=\"comfrim_msg\"></span></h4>");
document.write("</div>");
document.write("</div>");
document.write("<div class=\"modal-footer\">");
document.write("<input type=\"hidden\" id=\"comfrimId\"/>");
document.write("<input type=\"hidden\" id=\"comfrim_objectId\"/>");
document.write("<button type=\"button\" class=\"btn btn-default\" data-dismiss=\"modal\" onclick=\"_confirmDlg();comfrim();\">确定</button>");
document.write("<button type=\"button\" class=\"btn btn-default\" data-dismiss=\"modal\" onclick=\"_cancelDlg();\">取消</button>");
document.write("</div>");
document.write("</div>");
document.write("</div>");
document.write("</div>");

var fun;
/**
 * 页面中确认提示框
 * @param title 提示框标签
 * @param msg 提示信息
 * @param returnFun(b) 当用户点击按钮后触发的回调函数，如果点击OK则给回调函数传true,如果点击cancel则传false
 * 
 */
function messageComfrim(msg,returnFun)
{
    fun = returnFun;
    //$("#comfrim_title").html(title);
    $("#comfrim_msg").html(msg);
    $("#dlg_comfrim").modal("show"); 
}

function _closeDlg()
{
    if(fun != undefined)
    {
        fun(false);
    }
}
function _confirmDlg()
{
    eval(fun);
}
function _cancelDlg()
{
    if(fun != undefined)
    {
        fun(false);
    }
}